package com.tools.cleanmaster.cpucool;


import com.tools.cleanmaster.taskmain.ProcessItem;

import java.util.List;

/**
 * Created by wangguotao on 15/8/28.
 */
public class CpuTempInfo {
    private double cpuTemp;
    private double cpuOptimizerTemp;
    private boolean isProtect = false;
    private List<ProcessItem> mIcons;

    public CpuTempInfo(double cputemp, double cpuoptimizer, boolean protect, List<ProcessItem> items) {
        cpuTemp = cputemp;
        cpuOptimizerTemp = cpuoptimizer;
        mIcons = items;
        isProtect = protect;
    }

    public int getCpuTemp() {
        if (isProtect) {
            return (int) cpuTemp;
        } else {
            return (int) (cpuOptimizerTemp + cpuTemp);
        }
    }

    public List<ProcessItem> getProcessItems() {
        return mIcons;
    }
}
